-- Gamemode
include( 'shared.lua' )

function GM:HUDPaint()
	GAMEMODE:HUDDrawTargetID()
	--GAMEMODE:HUDDrawPickupHistory()
	--GAMEMODE:DrawDeathNotice( 0.85, 0.04 )
	local Tokens = LocalPlayer():GetNWInt("tokens")
	if Tokens == 0 then Tokens = "None" end

	
	drawCentered("Tokens: ".. Tokens)
end

function drawCentered( text )
	surface.SetFont("Default")
	local w, h = surface.GetTextSize( text )
	local border = 8
	local x = ( ScrW() - ( w + 2 * border ) ) / 3
	local y = ( ScrH() - ( h + 2 * border ) ) / 2
	draw.WordBox( border, x, y, text, "Default", Color( 50, 50, 75, 100 ), Color( 255, 255, 255, 255 ) )
end

function GM:HUDShouldDraw( name )
	local nodraw = {
		"CHudCrosshair",
		"CHudHealth"
	}
	for k,v in pairs(nodraw) do
		if name == v then
			return false
		end
	end
	
	return true;
end